The SimpleMenu Component > FSimpleMenu (object) |
FSimpleMenu (object)
The methods of the SimpleMenu component allow you to control all aspects of the component at runtime. You can create SimpleMenus; edit, add, and remove navigation items and separator bars; set or override basic parameters; and set additional runtime options. You don't need to use a constructor to access the methods of components.
You can use the FSimpleMenu methods to specify a handler function for push buttons, disable or enable buttons, and resize buttons without distortion at runtime.
Component methods do not perform error checking for type, as do other native ActionScript objects and actions. Therefore, you should validate parameters before passing them to methods.
Method name Description Adds either a button or a separator bar to the end of the SimpleMenu
component. Adds either a button or a separator bar at the specified index on the
SimpleMenu component. Retrieves the axis of the SimpleMenu. Gets the width of all the buttons. Retrieves an object with the Click Handler function's name and a reference
to the Retrieves the enabled state of the SimpleMenu component. Retrieves an object containing the label and itemType
properties of an item on the SimpleMenu component at the specified index. Retrieves the number of items on the SimpleMenu component. Retrieves the pixel number between each item on the Simple Menu component. Registers a skin element to a style property. Skin elements are registered
to properties in the first frame of the Read Me layer of each skin in
the library. Removes all items on the SimpleMenu component. Removes an item on the SimpleMenu component at the specified index. Replaces the item at the specified index on the SimpleMenu with a new
button or separator bar. Modifies the build of the component from either left-right or top-bottom.
The axis parameter must have a string value of either "horizontal",
"vertical", or a Boolean value of true (for the default "horizontal"
axis). Sets the width of all the buttons on the SimpleMenu component. Sets the handler for when an item on the SimpleMenu is clicked. The
handler is passed a reference to the SimpleMenu as well as the index of
the item clicked. Specifies the data provider from which to create items on the SimpleMenu.
Enables or disables the SimpleMenu. In the disabled state, the loading
box accepts no keyboard or mouse input. Specifies the number of pixels (an integer) in between each item on
the SimpleMenu. Sets an FStyleFormat property for an individual SimpleMenu instance.
Method summary for the FSimpleMenu object
obj in which the Click Handler function resides.